package org.vergil.core.service.impl;

import org.springframework.stereotype.Service;
import org.vergil.core.service.JwtService;
import org.vergil.dto.Jwt;
import org.vergil.dto.Playload;
import org.vergil.dto.User;
import org.vergil.utils.Encrypt;
import org.vergil.utils.JsonUtils;
import org.vergil.utils.JwtUtils;

import java.time.LocalDateTime;
import java.util.Base64;

/**
 * Created by vergil on 4/29/17.
 */
@Service
public class JwtServiceImpl implements JwtService {
    @Override
    public String LoginAndCreateJwt(User user) {
        return JwtUtils.EncodeJwt(user);
    }

    @Override
    public void LogoutAndClearJwt(String jwtContext) {
        Jwt jwt = JwtUtils.decodeJwt(jwtContext);
    }
}
